<extend name="Layout:layout_list" />
<block name="body_content_block">
    <table id="main_grid" class="easyui-datagrid" data-url="{:AddonU('SMS/get_server_list_json')}"></table>
    <div id="tb" style="padding:2px 5px;">
        <div style="margin-bottom: 5px; border-bottom:solid 1px #dddddd;">
            <a href="{:AddonU('SMS/server_edit')}" class="easyui-linkbutton lnk_grid_add" iconCls="icon-add" plain="true">新增</a>            
            <a href="{:AddonU('SMS/server_edit','id=varid')}" class="easyui-linkbutton lnk_grid_edit" iconCls="icon-edit" plain="true">编辑</a>
            <a href="{:AddonU('SMS/server_delete','id=varid')}" class="easyui-linkbutton lnk_grid_remove" iconCls="icon-remove" plain="true">删除</a>
            <a href="{:AddonU('SMS/server_export')}" class="easyui-linkbutton" iconCls="icon-save" plain="true">导出</a>
        </div>
    </div>
</block>
<block name="body_after_block">
    <script type="text/javascript">
        // 页面初始化
        var curd_grid = CurdGrid.newInstance();
        curd_grid.config({
            title: '短信服务器管理',
            toolbar: '#tb',
            columns: [[
                    {field: 'ck', checkbox: true},
                    {title: "租户ID", field: "siteIDText", sortable: true},
                    {title: "服务器名称", field: "serverName", sortable: true},
                    {title: "服务器地址", field: "host", sortable: true},
                    {title: "端口号", field: "port", sortable: true},
                    {title: "每条计费字符数", field: "contentLength", sortable: true},
                    {title: "发送间隔(秒)", field: "sendInterval", sortable: true},
                    {title: "备注信息", field: "remark", sortable: true},
                    {title: "创建时间", field: "createdTime", sortable: true},
                    {title: "编号", field: "id", hidden: true},
                ]],
        });
        curd_grid.init();
    </script>
</block>